# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=fbi
pkgver=28.0f94e99
pkgrel=3
pkgdesc='An accurate facebook account information gathering.'
groups=('blackarch' 'blackarch-social' 'blackarch-recon')
arch=('any')
url='https://github.com/xHak9x/fbi'
license=('GPL2')
depends=('python2' 'python2-requests')
makedepends=('git')
source=("git+https://github.com/xHak9x/$pkgname.git"
        "$pkgname.py.patch")
sha512sums=('SKIP'
            'c76c135cbb0468696a2fcbd3a46e2559bf7f32f83482a55f105783a3064f91f0bf012086ddd911dc1876c9dc4f8dccbd6b187287f5d161348c3468f51f856e98')

pkgver() {
  cd $pkgname

  echo $(git rev-list --count HEAD).$(git rev-parse --short HEAD)
}

prepare() {
  patch -p1 < "$pkgname.py.patch"
}

package() {
  cd $pkgname

  install -Dm 755 "$pkgname.py" "$pkgdir/usr/bin/$pkgname"
  install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" README.md
  install -Dm 644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}

